import request from '@/utils/request'
// 获取企业列表
export const getEnterprise = (params) => request.get('/park/enterprise', { params })
// 获取企业行业列表
export const getEnterpriseIndustry = () => request.get('/park/industry')
// 上传营业执照
export const upload = (data) => request.post('/upload', data)
// 增加企业
export const addEnterprise = (data) => request.post('/park/enterprise', data)
// 修改企业
export const editEnterprise = (data, id) => request.put('/park/enterprise', { ...data, id })
// 查看企业详细信息
export const getEnterpriseDetail = (id) => request.get(`/park/enterprise/${id}`)
// 删除企业
export const delEnterprise = (id) => request.delete(`/park/enterprise/${id}`)
// 查询可租赁楼宇
export const getBuilding = () => request.get('/park/rent/building')
// 添加/续租合同
export const addContract = (data) => request.post('/park/enterprise/rent', data)
// 获取合同列表
export const getContract = (id) => request.get(`/park/enterprise/rent/${id}`)
// 退租合同
export const delContract = (id) => request.delete(`/park/enterprise/rent/${id}`)
// 获取合同详情
export const getContractDetail = (id) => request.get(`/park/enterprise/${id}`)
